package com.ruoyi.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

import javax.validation.constraints.NotNull;

/**
 * 图书借阅对象 sys_lend_list
 *
 * @author mjx
 * @date 2023-12-29
 */
public class LendMessage extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键 */
    @NotNull(message = "借阅id不能为空")
    private Long lendId;

    /** 书id */
    @Excel(name = "书id")
    private Long bookId;

    /** 借阅的读者id */
    @Excel(name = "借阅的读者id")
    private Long userId;

    /** 借阅时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "借阅时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date lendDate;

    /** 应该归还时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "应该归还时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date shouldBackTime;

    /** 归还时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "归还时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date backDate;

    /** 创建时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "归还时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date createTime;

    /** 是否丢失（0没丢失，1丢失） */
    @Excel(name = "是否丢失", readConverterExp = "0=没丢失，1丢失")
    private Integer state;

    /** 是否显示该记录，0表示显示，1表示不显示 */
    @Excel(name = "是否显示该记录，0表示显示，1表示不显示")
    private Integer isDelete;

    /** 是否归还，0表示未归还，1表示已归还 */
    @Excel(name = "是否归还，0表示未归还，1表示已归还")
    private Integer isBack;

    /** 续借次数 */
    @Excel(name = "续借次数")
    private Integer renewCount;

    public Long getLendId() {
        return lendId;
    }

    public void setLendId(Long lendId) {
        this.lendId = lendId;
    }

    public Long getBookId() {
        return bookId;
    }

    public void setBookId(Long bookId) {
        this.bookId = bookId;
    }

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public Date getLendDate() {
        return lendDate;
    }

    public void setLendDate(Date lendDate) {
        this.lendDate = lendDate;
    }

    public Date getShouldBackTime() {
        return shouldBackTime;
    }

    public void setShouldBackTime(Date shouldBackTime) {
        this.shouldBackTime = shouldBackTime;
    }

    public Date getBackDate() {
        return backDate;
    }

    public void setBackDate(Date backDate) {
        this.backDate = backDate;
    }

    public Integer getState() {
        return state;
    }

    public void setState(Integer state) {
        this.state = state;
    }

    public Integer getIsDelete() {
        return isDelete;
    }

    public void setIsDelete(Integer isDelete) {
        this.isDelete = isDelete;
    }

    public Integer getIsBack() {
        return isBack;
    }

    public void setIsBack(Integer isBack) {
        this.isBack = isBack;
    }

    public Integer getRenewCount() {
        return renewCount;
    }

    public void setRenewCount(Integer renewCount) {
        this.renewCount = renewCount;
    }

    @Override
    public Date getCreateTime() {
        return createTime;
    }

    @Override
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
                .append("lendId", getLendId())
                .append("bookId", getBookId())
                .append("userId", getUserId())
                .append("lendDate", getLendDate())
                .append("shouldBackTime", getShouldBackTime())
                .append("backDate", getBackDate())
                .append("createTime", getCreateTime())
                .append("state", getState())
                .append("isDelete", getIsDelete())
                .append("remark", getRemark())
                .append("isBack", getIsBack())
                .append("renewCount", getRenewCount())
                .toString();
    }
}
